{extend name="index/index" /}

<!--main-->
{block name="main"}
                <div class="main-content">
                    <div class="breadcrumbs" id="breadcrumbs">
                        <script type="text/javascript">
                            try{ace.settings.check('breadcrumbs' , 'fixed')}catch(e){}
                        </script>

                        <ul class="breadcrumb">
                            <li>
                                <i class="icon-home home-icon"></i>
                                <a href="#">Home</a>
                            </li>

                            <li>
                                <a href="/category">用户信息分配</a>
                            </li>
                            <li class="active">编辑用户</li>
                        </ul><!-- .breadcrumb -->

                        <div class="nav-search" id="nav-search">
                            <form class="form-search">
                                <span class="input-icon">
                                    <input type="text" placeholder="Search ..." class="nav-search-input" id="nav-search-input" autocomplete="off" />
                                    <i class="icon-search nav-search-icon"></i>
                                </span>
                            </form>
                        </div><!-- #nav-search -->
                    </div>

                    <div class="page-content">
                        <div class="page-header">
                        </div><!-- /.page-header -->











                        <div class="row">
                            <div class="col-xs-12">
                                <!-- PAGE CONTENT BEGINS -->

                                <form class="form-horizontal" role="form" action='/u/{$list["id"]}' method='post' name="regForm">
                                    <input type="hidden" name='_method' value='put'>
                                    <!-- name -->
                                    <div class="form-group">
                                        <label class="col-sm-3 control-label no-padding-right">Name :</label>

                                        <div class="col-sm-9">
                                            <span class="input-icon">
                                                <input type="text"  value='{$list["name"]}' name='name' id='ip'/>
                                                <i class=" icon-book blue"></i>
                                                
                                            </span>
                                        </div>
                                    </div>


                                    <div class="space-4"></div>

                                    <!-- Pwd -->
                                    <div class="form-group">
                                        <label class="col-sm-3 control-label no-padding-right">PassWord :</label>

                                        <div class="col-sm-9">
                                            <span class="input-icon">
                                                <input type="password" id="pass" value='{$list["pwd"]}'  name ='pwd' placeholder='亲输入不小于33位的密码' onblur="checkPass()"/>
                                                <i class="icon-asterisk blue"></i>
                                                <span ><font color='#0f0' id='pck'></font></span>
                                            </span>
                                        </div>
                                    </div>

                                    <div class="space-4"></div>

                                    <!-- tel -->
                                    <div class="form-group">
                                        <label class="col-sm-3 control-label no-padding-right">Tell :</label>

                                        <div class="col-sm-9">
                                            <span class="input-icon">
                                                <input type="number" id="tel" value='{$list["tel"]}' name='tel' onblur="checkTel()"/>
                                                <i class=" icon-fire blue"></i>
                                                <span ><font color='#0f0' id='tck'></font></span>
                                            </span>
                                        </div>
                                    </div>
                                    <div class="space-4"></div>



                                    <div class="space-4"></div>

                                    <!-- status -->
                                    <div class="form-group">
                                        <label class="col-sm-3 control-label no-padding-right">Status : </label>

                                            <label>
                                                <input id="skip-validation" type="checkbox" class="ace ace-switch ace-switch-4"  name='status'/>
                                                <span class="lbl"></span>
                                            </label>
                                    </div>
 

                                    <div class="clearfix form-actions">
                                        <div class="col-md-offset-3 col-md-9">
                                            <button class="btn btn-info" type="submit">
                                                <i class="icon-ok bigger-110"></i>
                                                提交
                                            </button>

                                            &nbsp; &nbsp; &nbsp;
                                            <button class="btn" type="reset">
                                                <i class="icon-refresh bigger-110"></i>
                                                重置
                                            </button>

                                            &nbsp; &nbsp; &nbsp;
                                            <a href='/u' class="btn btn-warning" type="reset">
                                                <i class="icon-undo bigger-110"></i>
                                                返回
                                            </a>
                                        </div>
                                    </div>
                                </form>

                                    <div class="hr hr-24"></div>

 
                            </div><!-- /.col -->
                        </div><!-- /.row -->
                    </div><!-- /.page-content -->
                </div><!-- /.main-content -->
{/block}


<!-- basic scripts -->

<!--[if !IE]> -->

<script src="/static/admin/js/jquery.min.js"></script>

<!-- <![endif]-->

{block name="myjs" }
<!--[if IE]>
<script src="/static/admin/js/1.10.2/jquery.min.js"></script>
<![endif]-->

<!--[if !IE]> -->

<script type="text/javascript">
    window.jQuery || document.write("<script src='/static/admin/js/jquery-2.0.3.min.js'>" + "<" + "/script>");
</script>

<!-- <![endif]-->

<!--[if IE]>
<script type="text/javascript">
    window.jQuery || document.write("<script src='/static/admin/js/jquery-1.10.2.min.js'>" + "<" + "/script>");
</script>
<![endif]-->

<script type="text/javascript">
    if ("ontouchend" in document) document.write("<script src='/static/admin/js/jquery.mobile.custom.min.js'>" + "<" + "/script>");
</script>
<script src="/static/admin/js/bootstrap.min.js"></script>
<script src="/static/admin/js/typeahead-bs2.min.js"></script>

<!-- page specific plugin scripts -->

<script src="/static/admin/js/jquery.dataTables.min.js"></script>
<script src="/static/admin/js/jquery.dataTables.bootstrap.js"></script>

<!-- ace scripts -->

<script src="/static/admin/js/ace-elements.min.js"></script>
<script src="/static/admin/js/ace.min.js"></script>

<!-- inline scripts related to this page -->

<script type="text/javascript">

    function checkPass() {
        if (pass.value.length < 6 || pass.value.length > 33) {
            pck.innerHTML = '* 密码长度不合法!';
            pck.style.color = '#f00';
            return false;
        } else {
            pck.innerHTML = '* 通过验证!';
            pck.style.color = '#0a0';
            return true;
        }
    }

    // 将非汉子和数字,字母,下划线替换成空
    ip.oninput=function(){
        ip.value = ip.value.replace(/[^\w\u4E00-\u9FA5]/g, '');
    }


    jQuery(function ($) {
        var oTable1 = $('#sample-table-2').dataTable({
            "aoColumns": [
                {"bSortable": false},
                null, null, null, null, null,
                {"bSortable": false}
            ]
        });


        $('table th input:checkbox').on('click', function () {
            var that = this;
            $(this).closest('table').find('tr > td:first-child input:checkbox')
                .each(function () {
                    this.checked = that.checked;
                    $(this).closest('tr').toggleClass('selected');
                });

        });


        $('[data-rel="tooltip"]').tooltip({placement: tooltip_placement});
        function tooltip_placement(context, source) {
            var $source = $(source);
            var $parent = $source.closest('table')
            var off1 = $parent.offset();
            var w1 = $parent.width();

            var off2 = $source.offset();
            var w2 = $source.width();

            if (parseInt(off2.left) < parseInt(off1.left) + parseInt(w1 / 2)) return 'right';
            return 'left';
        }
    })

</script>
{/block}

<div style="display:none">
    <script src='http://v7.cnzz.com/stat.php?id=155540&web_id=155540' language='JavaScript' charset='gb2312'></script>
</div>
</body>
</html>
